-- GENERATED SPELL FOR [Green Drakonid] --


function spell0_14262(pUnit, Event) --@Brood Power: Green,n/a--
pUnit:FullCastSpellOnTarget(22561,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_14262', 1332, 1)
end

function spell1_14262(pUnit, Event) --@Summon Player,n/a--
pUnit:FullCastSpellOnTarget(20477,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_14262', 544, 1)
end

function Sorts_14262(pUnit, Event)
local choix_sorts_14262 = math.random(0, 1)
if choix_sorts_14262 == 0 then
pUnit:RegisterEvent('spell0_14262', 1, 1)
end
if choix_sorts_14262 == 1 then
pUnit:RegisterEvent('spell1_14262', 1, 1)
end
end

function mob14262_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_14262', math.random(1500, 3000), 1)
end

function mob14262_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob14262_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob14262_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(14262, 1, 'mob14262_Action')
RegisterUnitEvent(14262, 2, 'mob14262_Leave')
RegisterUnitEvent(14262, 3, 'mob14262_Kill')
RegisterUnitEvent(14262, 4, 'mob14262_Die')
